/**
 * Copyright (c) 2013-Now http://jeesite.com All rights reserved.
 */
package com.jeesite.modules.zx.course.exercises.user.entity;

import org.hibernate.validator.constraints.Length;

import java.math.BigDecimal;
import java.util.Date;
import com.jeesite.common.mybatis.annotation.JoinTable;
import com.jeesite.common.mybatis.annotation.JoinTable.Type;
import com.fasterxml.jackson.annotation.JsonFormat;

import com.jeesite.common.entity.DataEntity;
import com.jeesite.common.mybatis.annotation.Column;
import com.jeesite.common.mybatis.annotation.Table;
import com.jeesite.common.mybatis.mapper.query.QueryType;
import com.jeesite.modules.zx.course.entity.Tcourses;

/**
 * 课程练习记录表Entity
 * @author zpp
 * @version 2020-02-17
 */
@Table(name="t_course_exercises_user", alias="a", columns={
		@Column(name="id", attrName="id", label="主键", isPK=true),
		@Column(name="course_id", attrName="courseId", label="课程id"),
		@Column(name="course_title", attrName="courseTitle", label="课程主题", queryType=QueryType.LIKE),
		@Column(name="state", attrName="state", label="数据状态"),
		@Column(includeEntity=DataEntity.class),
		@Column(name="barbecue_time", attrName="barbecueTime", label="练习时间"),
		@Column(name="barbecue_edtime", attrName="barbecueEdtime", label="练习完成时间"),
		@Column(name="score", attrName="score", label="得分"),
		@Column(name="course_hourse_id", attrName="courseHourseId", label="课时id"),
		@Column(name="course_hourse_title", attrName="courseHourseTitle", label="课时标题"),
		
	}, orderBy="a.update_date DESC"
)
public class TcourseExercisesUser extends DataEntity<TcourseExercisesUser> {
	
	private static final long serialVersionUID = 1L;
	private String courseId;		// 课程id
	private String courseTitle;		// 课程主题
	private Integer state;		// 数据状态
	private Date barbecueTime;		// 练习时间
	private Date barbecueEdtime;		// 练习完成时间
	private BigDecimal score;		// 得分
	private Tcourses tcourses;
	private String courseHourseId;
	private String courseHourseTitle;
	public Tcourses getTcourses() {
		return tcourses;
	}

	public void setTcourses(Tcourses tcourses) {
		this.tcourses = tcourses;
	}

	public TcourseExercisesUser() {
		this(null);
	}

	public TcourseExercisesUser(String id){
		super(id);
	}
	
	@Length(min=0, max=50, message="课程id长度不能超过 50 个字符")
	public String getCourseId() {
		return courseId;
	}

	public void setCourseId(String courseId) {
		this.courseId = courseId;
	}
	
	@Length(min=0, max=255, message="课程主题长度不能超过 255 个字符")
	public String getCourseTitle() {
		return courseTitle;
	}

	public void setCourseTitle(String courseTitle) {
		this.courseTitle = courseTitle;
	}
	
	

	
	public Integer getState() {
		return state;
	}

	public void setState(Integer state) {
		this.state = state;
	}
	
	
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	public Date getBarbecueTime() {
		return barbecueTime;
	}

	public void setBarbecueTime(Date barbecueTime) {
		this.barbecueTime = barbecueTime;
	}
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	public Date getBarbecueEdtime() {
		return barbecueEdtime;
	}

	public void setBarbecueEdtime(Date barbecueEdtime) {
		this.barbecueEdtime = barbecueEdtime;
	}
	
	public BigDecimal getScore() {
		return score;
	}

	public void setScore(BigDecimal score) {
		this.score = score;
	}

	public String getCourseHourseId() {
		return courseHourseId;
	}

	public void setCourseHourseId(String courseHourseId) {
		this.courseHourseId = courseHourseId;
	}

	public String getCourseHourseTitle() {
		return courseHourseTitle;
	}

	public void setCourseHourseTitle(String courseHourseTitle) {
		this.courseHourseTitle = courseHourseTitle;
	}
	
}